<?php include atemplate('header');?>

<table width="96%" border="0" cellspacing="0" cellpadding="0">
  <tr>
    <td height="30" align="left" bgcolor="#B51C00"> 　<span class="STYLE8">公告管理</span></td>
    <td width="100" align="center" bgcolor="#B51C00"><a href="/admin/index.php?do=news&ac=add" class="link1">公告发布</a></td>
  </tr>
</table>
<table width="96%" border="0" cellspacing="0" cellpadding="0">
  <tr bgcolor="#FFFFF7">
    <td width="40" align="center" valign="middle" class="STYLE7">ID</td>
    <td height="30" align="left" >标题</td>
    <td height="30" align="left" >发布时间</td>
    <td width="60" align="center" valign="middle" colspan="2" >操作</td>
  </tr>
  <?php foreach ($list as $key=>$val) {
	$key %2 == 0 ? $bgcolor = 'bgcolor="#FAFAFA"' : $bgcolor = 'bgcolor="#FFFFF7"';
?>
  <tr <?php echo $bgcolor;?>>
    <td width="40" align="center" valign="middle" class="STYLE7"><?php echo $val['id'];?></td>
    <td height="30" align="left" ><a href="/news.php?contentid=<?php echo $val['id'];?>" target="_blank" class="link2"><?php echo $val['title'];?></a></td>
    <td height="30" align="left" ><?php echo date('Y-m-d H:i:s',$val['posttime']);?></td>
    <td width="60" align="center" valign="middle" ><a href="/admin/index.php?do=news&ac=edit&id=<?php echo $val['id'];?>">编辑</a></td>
    <td width="80" height="40" align="center" valign="middle" ><a href="/admin/index.php?do=news&ac=del&id=<?php echo $val['id'];?>" onclick="return  confirm('是否真的删除此公告');">删除</a></td>
  </tr>
  <?php }?>
</table>
<table width="96%" border="0" cellspacing="0" cellpadding="0">
  <tr>
    <td height="30" align="right" class="page"><?php echo $pagestr;?></td>
  </tr>
</table>
<?php include atemplate('footer');?>
